﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using mock_ehr_lib.Model.Infobutton;

namespace mock_ehr_lib.Model.OrderEntry
{
    public class Order : IInfobuttonProvider
    {
        public string OrderID { get; set; }
        public int PatientID { get; set; }
        public string Type { get; set; }
        public DateTime? EndDate { get; set; }
        public string Description { get; set; }
        public string Status { get; set; }
        // Infobutton params
        public string Institute { get; set; }
        public string MedCode { get; set; }
        public string Context { get; set; }

        public InfobuttonParameter[] GetParameters()
        {
            return new []
                       {
                            new InfobuttonParameter { Name = "info_institute", Value = Institute },
                            new InfobuttonParameter { Name = "info_med", Value = MedCode },
                            new InfobuttonParameter { Name = "info_context", Value = Context }
                        };
        }
    }
    //TODO use this instead of string type?
    public enum OrderType
    {
        Medication,
        Lab,
        Nursing,
        Radiology,
        Diet
    }
}
